Ext.define('com.hh.usersystem.org.OrgChange', {
	extend : 'com.hh.base.BaseWindow',
	title : '切换身份',
	width : 300,
	height : 140,
	modal : true,
	layout : 'border',
	closable : false,
	maximizable : false,
	minimizable : false,
	constructor : function(config) {
		this.config = config || {};
		this.superclass.constructor.call(this, this.config);
		var form = Ext.create('com.hh.base.BaseFormPanel', {
			url : 'usersystem-App-changeOrg',
			padding : '1',
			items : [ {
				xtype : 'widgetComboBox',
				fieldLabel : '选择身份',
				name : 'currOrgId',
				action : 'usersystem-App-queryLoginOrgList',
				columnWidth : 1,
				allowBlank : true,
				value : static_var.currOrg.id
			} ],
			buttons : [ {
				iconCls : 'yes',
				text : '保    存',
				handler : function() {
					var win = this.up('window');
					var callback = function(result) {
						static_var.currOrg = result;
						win.close();
					};
					FormPanel.submit(this.up('form'), {afcallback:callback});
				}
			} ]
		});
		this.add(form);
	}
});